/*

Displays a small lamp with a simple light effect.

Usage (Level NPC):

function onCreated() {
  this.join("object_lampsmall");
}

*/

//#CLIENTSIDE

function onCreated() {
  // Set Image
  setimgpart("lampanimation.gif", 0, 0, 20, 36);
  // Avoid Blocking
  dontblock();
  // Check if Light Effects Enabled
  if (lighteffectsenabled) {
    // Show Light
    with (findimg(200)) {
      x = thiso.x - 3.5;
      y = thiso.y - 3;
      // Light Image
      image = "light2.png";
      // Zoom Effect
      zoom  = 0.6;
      // Color
      red   = 1;
      green = 0.25;
      blue  = 0;
      // Transparency
      alpha = 0.99;
    }
  }
}
